package com.itheima.order.feign;

import com.itheima.goods.pojo.Address;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;

/**
 * @author wang
 * @description
 * @date 2021/7/31 15:28
 */
@FeignClient("users4shopping")
@Component
@RequestMapping("/address")
public interface UserFeign {
    @GetMapping("/{username}")
    List<Address> findByUserId(@PathVariable String username);
}
